<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:c="http://java.sun.com/jsp/jstl/core">
    <ui:composition xmlns:ui="http://java.sun.com/jsf/facelets"
                    template="./AdminTemplate.xhtml">
        <ui:define name="Title">
            <title>Order</title>
        </ui:define>
        <ui:define name="content">
            <h:form>
                <p:growl id="msgs" showDetail="true"/>  
                <h:panelGrid columns="2" cellpadding="5">
                    <h:selectOneMenu id="city" value="#{addVehicle.brandName}">
                        <f:selectItem itemLabel="Select Brand" itemValue="" />
                        <f:selectItems value="#{addVehicle.listBrand}" />
                        <p:ajax update="suburbs"
                                listener="#{addVehicle.updateTypeVeicle}" />
                    </h:selectOneMenu>
                    <br/>
                    <h:selectOneMenu id="suburbs" value="#{addVehicle.typeVehicleName}">
                        <f:selectItem itemLabel="Select TypeVehicle" itemValue="" />
                        <f:selectItems value="#{addVehicle.listTypeVehicle}" />
                    </h:selectOneMenu>
                </h:panelGrid>
                <p:separator />
                <p:commandButton value="Submit" update="msgs" actionListener="#{addVehicle.displayLocation}" id="btnSubmit"/>

            </h:form>
        </ui:define>
    </ui:composition>
</html>
